<?php
namespace Oa\Model;

use Think\Model;

/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2017/7/26
 * Time: 14:47
 * @author: yfl
 * @QQ: 554665488
 * @description:
 * @time:
 */
class UserModel extends Model
{
    public function verifyLogin(array $data)
    {
        $res = $this->where(array('mobile' => $data['mobile']))->field('mobile,password')->find();
        if (!empty($res)) {
            if ($res['password'] == $data['password']) {
                  return true;
            }else{
                return false;
            }
        } else {
            return false;
        }
    }
}